import Vue from "vue"

import VueRouter from "vue-router"

import ElementUI from 'element-ui';


import 'element-ui/lib/theme-chalk/index.css';

Vue.use(VueRouter)

Vue.use(ElementUI);

const originalPush = VueRouter.prototype.push

VueRouter.prototype.push = function push(location) {
  return originalPush.call(this, location).catch(err => err)
}

const routes = [
    {
        path: "/login",
        component: () => import(/*webpackChunkName:'login'*/"../components/Login")
    },
]

export default new VueRouter( {
    routes
})